package com.apesource.project02.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.util.Date;

/**
 * @version 1.0
 * @auther:暮雪
 * @date:2025/9/18
 */
@TableName("messages")
public class Message {
    @TableId(value = "message_id",type = IdType.AUTO)
    private int messageId;

    @TableField("user_id")
    private int userId;

    @TableField("content")
    private String content;
    @TableField("send_time")
    private Date sendTime;

    public Message() {
    }

    public Message(int userId, String content, Date sendTime) {
        this.userId = userId;
        this.content = content;
        this.sendTime = sendTime;
    }

    public Message(int messageId, int userId, String content, Date sendTime) {
        this.messageId = messageId;
        this.userId = userId;
        this.content = content;
        this.sendTime = sendTime;
    }

    public int getMessageId() {
        return messageId;
    }

    public void setMessageId(int messageId) {
        this.messageId = messageId;
    }

    public int getUserId() {
        return userId;
    }

    public void setUserId(int userId) {
        this.userId = userId;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public Date getSendTime() {
        return sendTime;
    }

    public void setSendTime(Date sendTime) {
        this.sendTime = sendTime;
    }
}
